#include <stdio.h>

int mystrcmp(char *s1, char *s2);

void main()
{
    int compare;
    char src[100], dest[100];
    gets(src);
    gets(dest);

    compare = mystrcmp(src, dest);
    if ( compare == 0) 
    {
        printf("equal");
    }
    else if (compare == -1) 
    {
        printf("smaller");
    }
    else
    {
        printf("bigger");
    }
}

int mystrcmp(char *src, char *dest)
{
    char *p, *q;
    p = src;
    q = dest;
    while (*p == *q)
    {
        if (*p == 0) 
        {
            return 0;
        }
        ++p;
        ++q;
    }
    if (*p > *q) 
    {
        return 1;
    }
    else
    {
        return -1;
    }
}
